package com.lzw.mapper;

import com.lzw.bean.RoleMenu;
import com.lzw.bean.UserRole;
import com.lzw.common.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * Created by 林志伟 on 2017/5/11.
 */

@Mapper
@Repository
public interface RoleMenuMapper extends BaseMapper<UserRole> {

    public int insertAll(List<RoleMenu> roleMenus);

    public int deleteOther(@Param("role_id") int role_id, @Param("menu_ids") int[] menu_ids);

    public UserRole findByRoleIdMenuId(@Param("role_id") int role_id, @Param("menu_id") int menu_id);
}
